﻿using System;
using System.Collections;
using System.Collections.Generic;
using System.Text;

namespace Components
{
    public class QB : Hashtable
    {
        public static QB Entity
        {
            get { return new QB(); }
        }

        public QB AddParam(string key, object v)
        {
            this.Add(key, v);
            return this;
        }

        public Hashtable ToTable()
        {
            return (Hashtable) this;
        }

        public string[] ValuesToArray()
        {
            if (null == this) return null;
            List<string> str = new List<string>();
            foreach (var k in this.Values)
            {
                str.Add(Validation.ToString(k));
            }

            return str.ToArray();
        }
    }
}
